<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript">
        window.onload = function () {
            var img = document.getElementsByTagName("img")[0];
            img.onmouseover = function () {
                img.src = "jf.gif";
            };
            img.onmouseout = function () {
                img.src = "wm.jpg";
            };
        };
    </script>
</head>
<body>
<img src="wm.jpg" alt="">
</body>
</html>